﻿using System;
using System.Collections.Generic;
using System.Data;
using System.Text;
using DAL;
using Utils;

namespace BLL
{
   public class TrainBiz
    {
       TrainDao trainDao = new TrainDao();
       public bool Insert(string tableName, SortedDictionary<string, string> sdList)
       {
           return trainDao.Insert(tableName, sdList);
       }


       public bool Update(string tableName, SortedDictionary<string, string> sdList)
       {
           return trainDao.Update(tableName, sdList);
       }



        #region 培训
        public bool DeleteOneInfo(string trainID)
        {
            return trainDao. DeleteOneInfo( trainID);
        }
        //获取一条记录
        public DataTable GetOneInfo(string trainID)
        {
            return trainDao.GetOneInfo(trainID);
        }
        
        //列表
        public DataTable GetLists(string serWord, string deptName, string bTime, string eTime)
        {
            return trainDao.GetLists(serWord, deptName, bTime, eTime);
            //if (dataSet.Tables[0].Rows.Count <= 0)
            //{
            //    for (int i = 0; i < 5; i++)
            //    {
            //        DataRow dr = dataSet.Tables[0].NewRow();
            //        dataSet.Tables[0].Rows.Add(dr);
            //    }
            //}
           
        }
        #endregion
    }
}
